<?xml version="1.0" encoding="UTF-8"?>
<!--
To change this template, choose Tools | Templates
and open the template in the editor.
-->
<!DOCTYPE html>
<html 
		xmlns="http://www.w3.org/1999/xhtml"
		xmlns:p="http://primefaces.org/ui"
		xmlns:h="http://java.sun.com/jsf/html"
		xmlns:f="http://java.sun.com/jsf/core"
		>
<h:head>
    <title>#{rotulos.labelLogin}</title>
    <script type="text/javascript" >
        function emptyLogin(login){
            if(login.value != ""){
                return true;
            }else
                {
                    alert("Digite o login");
                    return false;
                }
            
        }

    </script>
</h:head>
<h:body>
    <br/>
    <br/>
    <center>
    <p:panel header="#{rotulos.labelLogin}" style="text-align:left;width:400px;">
        <h:panelGrid columns="3" id="grid">
    <form method="post" action="validaLogin.do">
        <p:outputLabel value="#{rotulos.labelUser} " for="username"/>
        <h:inputText value="" id="username"/><br/>
        <p:outputLabel value="#{rotulos.labelPassword} " for="password"/>
        <h:inputSecret value="" id="password"/><br/>
        <h:commandButton type="submit" value="#{rotulos.labelLogin}" onclick="return emptyLogin(username);"/>
        <h:commandButton type="reset" value="#{rotulos.clear}"/>
    </form>
        </h:panelGrid>
    </p:panel>
        <br/>
        <h:form id="forgotregister">
        <p:commandButton  value="#{rotulos.labelRegister}" action="#{userController.prepRegisterUser}"/>
        <p:commandButton  value="#{rotulos.labelForgotPassword}" action="#{userController.prepForgotPassword}"/>
        </h:form>
    </center>
</h:body>
</html>
